﻿using System.Web.Mvc;
using TeamCityMonitor.Repository;
using TeamCityMonitor.Repository.Caches;
using TeamCitySharp.DomainEntities;

namespace TeamCityMonitor.Controllers
{
    public class HeaderController : Controller
    {
        private Server serverInfo;

        public HeaderController()
        {
            serverInfo = new TeamCityRepository(new UserPictureRepository()).GetServerInfo();
        }

        public ActionResult Header()
        {
            ViewBag.Server = serverInfo;

            return PartialView("Header", serverInfo);
        }
    }
}
